import Vue from 'vue'
import Vuex from 'vuex'
import user from '@/store/modules/user'
import getters from './getters'

Vue.use(Vuex)

const store = new Vuex.Store({
  modules: {
    user
  },
  getters,
	mutations: {
		setUserInfo(state,data) {
			console.log(state)
			state.user = data;
			uni.setStorageSync('user',data);
		}
	},
})

export default store
